home *** CD-ROM | disk | FTP | other *** search
/ Mission 3 / Mission 3.zip / Mission 3.iso / tools / facevalu / examples / utildemo / userwork.lst < prev   
File List  |  1998-03-29  |  6KB  |  123 lines

  1. '
  2. ' *** Replace the two relevant FV-written "user_"-routines with these (commented): ***
  3. > PROCEDURE user_on_open
  4. '
  5. ' This procedure is called when the program is run, after the RSC is
  6. ' loaded and just before the main loop. You can open program windows,
  7. ' toolboxes etc. here, or  init things for your program like
  8. ' loading an *.INF or .DAT file.
  9. '
  10. ' If run as an accessory, this procedure is called EVERY TIME
  11. ' THE ACCESSORY IS OPENED. If you need to do anything just ONCE,
  12. ' like disable menu-entries spesific to PROGRAM execution, set a global
  13. ' flag here to avoid doing things EVERY time the accessory is opened.
  14. '
  15. ' ΩΩwsnippetΩΩ  - Wrinkle code: (don't change or delete this flag)
  16. '
  17. ' ********* I have removed all the window open calls the wrinkles had placed here, ************
  18. ' ********* better to put it in the menu and let the user have control             ************
  19. '
  20. ' ΩΩwsnippetΩΩ  - End of Wrinkle code: (don't change or delete this flag)
  21. '
  22. RETURN
  23. > PROCEDURE user_rsc_interact(index&,tree&,object&,mc&,sub_me&)
  24. '
  25. '  <index&> is the index of this window in window_array&(index&,x)
  26. '           If the object tree is the normal menu bar, <index&>=-1
  27. '   <tree&> is the object tree number
  28. ' <object&> is the object that was selected (clicked on OR shortcut)
  29. '     <mc&> is the number of clicks (1=normal/2=double clicked/1 if shortcut)
  30. ' <sub_me&> is the chosen menuitem in a popup menu
  31. '
  32. SELECT tree&
  33. '
  34. ' ------------------------------------------------------------------------
  35. '
  36. CASE menu&
  37. SELECT object&
  38. CASE dm_about&
  39.   ~@alert_standard(1,about_alert&,"")                      !just an about-alert
  40. CASE dm_openall&
  41.   ~@calendar_win_open(6,icfyclnd&,3,":")                   !open all the wrinkles at once
  42.   ~@win_open_dialog(6,fvw_calc&,icfycalc&)
  43.   ~@midi_keyboard_win_open(0,6,icfymidi&)
  44.   ~@puzzle_win_open(6,icfypuzl&)
  45.   ~@keyboard_tester_win_open(6,icfykeyb&)
  46.   ~@convert_win_open(6,icfyconv&)
  47.   ~@color_selector_win_open(6,-1,1,-1,icfycsel&)
  48.   ~@ruler_win_open(icfyrule&,0)
  49.   ~@minesweeper_win_open(6,icfymine&)
  50. CASE dm_openiconify&
  51.   ~@calendar_win_open(6,icfyclnd&,3,":")                    !open all at once...
  52.   ~@win_open_dialog(6,fvw_calc&,icfycalc&)
  53.   ~@midi_keyboard_win_open(0,6,icfymidi&)
  54.   ~@puzzle_win_open(6,icfypuzl&)
  55.   ~@keyboard_tester_win_open(6,icfykeyb&)
  56.   ~@convert_win_open(6,icfyconv&)
  57.   ~@color_selector_win_open(6,-1,1,-1,icfycsel&)
  58.   ~@ruler_win_open(icfyrule&,0)
  59.   ~@minesweeper_win_open(6,icfymine&)
  60.   @win_iconify_all                                          !...and iconify
  61. CASE dm_closeall&
  62.   @win_close_all                                            !close all windows
  63. CASE dm_calc&
  64.   ~@win_open_dialog(6,fvw_calc&,icfycalc&)                  !open the calkulator
  65. CASE dm_calendar&
  66.   ~@calendar_win_open(6,icfyclnd&,3,":")                    !open the calendar
  67. CASE dm_mines&
  68.   ~@minesweeper_win_open(6,icfymine&)                       !open the minesweeper game
  69. CASE dm_puzzle&
  70.   ~@puzzle_win_open(6,icfypuzl&)                            !open the puzzle game
  71. CASE dm_midi&
  72.   ~@midi_keyboard_win_open(0,6,icfymidi&)                   !open the midi keyboard
  73. CASE dm_keyb&
  74.   ~@keyboard_tester_win_open(6,icfykeyb&)                   !open the keyboard tester
  75. CASE dm_scol&
  76.   ~@color_selector_win_open(6,-1,1,-1,icfycsel&)            !open the color selector
  77. CASE dm_rule&
  78.   ~@ruler_win_open(icfyrule&,0)                             !open the ruler
  79. CASE dm_convert&
  80.   ~@convert_win_open(6,icfyconv&)                           !open the concerter
  81. CASE dm_quit&
  82.   exit_program!=TRUE
  83. CASE dm_iconify&
  84.   @win_iconify(-1)                                          !iconify the top window
  85. CASE dm_iconify_all&
  86.   @win_iconify_all                                          !iconify all windows
  87. CASE dm_uniconify&
  88.   @win_uniconify(-1)                                        !uniconify the top window
  89. CASE dm_uniconify_all&
  90.   @win_uniconify_all                                        !uniconify all windows
  91. CASE dm_cycle_windows&
  92.   @win_cycle                                                !cycle the windows
  93. ENDSELECT
  94. '
  95. ' ------------------------------------------------------------------------
  96. ' *** The code below is automatically placed there by the Wrinkles themselves. Do not touch.
  97. ' *** You do not have to worry about the workings of these, they will do their job quietly & uncomplaining...! ;-)
  98. '
  99. ' ΩΩwsnippetΩΩ  - Wrinkle code: (don't change or delete this flag)
  100. CASE fvw_clnd&                         !ΩΩFVW:calendarΩΩ
  101. c$=@calendar_do$(index&,object&)        !ΩΩFVW:calendarΩΩ
  102. CASE fvw_calc&                                !ΩΩFVW:calculatorΩΩ
  103. @calculator_do(index&,object&)              !ΩΩFVW:calculatorΩΩ
  104. CASE fvw_midi&                                          !ΩΩFVW:midi_keyboardΩΩ
  105. ~@midi_keyboard_do(index&,object&)                    !ΩΩFVW:midi_keyboardΩΩ
  106. CASE fvw_puzl&                                                !ΩΩFVW:puzzleΩΩ
  107. ~@puzzle_do(index&,object&)                                 !ΩΩFVW:puzzleΩΩ
  108. CASE fvw_keyb&                                        !ΩΩFVW:keyboard_testerΩΩ
  109. @keyboard_tester_do(index&,object&,sub_me&,mc&)     !ΩΩFVW:keyboard_testerΩΩ
  110. CASE fvw_conv&                                   !ΩΩFVW:convertΩΩ
  111. @convert_do(index&,object&,sub_me&)            !ΩΩFVW:convertΩΩ
  112. CASE fvw_csel&                                            !ΩΩFVW:color_selectorΩΩ
  113. ~@color_selector_do(index&,object&,mc&)                 !ΩΩFVW:color_selectorΩΩ
  114. CASE fvw_rule&                                               !ΩΩFVW:rulerΩΩ
  115. ~@ruler_do(index&,object&,sub_me&,mc&)                     !ΩΩFVW:rulerΩΩ
  116. CASE fvw_mine&                                                     !ΩΩFVW:minesweeperΩΩ
  117. ~@minesweeper_do(index&,object&)                                 !ΩΩFVW:minesweeperΩΩ
  118. ' ΩΩwsnippetΩΩ  - End of Wrinkle code: (don't change or delete this flag)
  119. '
  120. ENDSELECT
  121. RETURN
  122. '
  123.